xen/xsm: Compile error due to naming clash between XSM and EFI runtime
authorJames Carter <jwcart2@tycho.nsa.gov>
Sat, 17 Sep 2011 15:20:58 +0000 (16:20 +0100)
committerJames Carter <jwcart2@tycho.nsa.gov>
Sat, 17 Sep 2011 15:20:58 +0000 (16:20 +0100)
The problem is that efi_runtime_call is the name of both a function in
xen/arch/x86/efi/runtime.c and a member of the xsm_operations struct
in xen/include/xsm/xsm.h. This causes the macro "#define
efi_runtime_call(x) efi_compat_runtime_call(x)" on line 15 of
xen/arch/x86/x86_64/platform_hypercall.c to cause the above compile
error.

Renaming the XSM struct member fixes the problem.

Signed-off-by: James Carter <jwcart2@tycho.nsa.gov>
Acked-by: Jan Beulich <jbeulich@suse.com>
xen/arch/x86/platform_hypercall.c
xen/include/xsm/xsm.h

index db5554c47fde5aefb016a9f2fe6807e00ce3d77d..d10024ae9483a31b7c29b507b25a07749b306034 100644 (file)
@@ -306,7 +306,7 @@ ret_t do_platform_op(XEN_GUEST_HANDLE(xen_platform_op_t) u_xenpf_op)
         break;
 
     case XENPF_efi_runtime_call:
-        ret = xsm_efi_runtime_call();
+        ret = xsm_efi_call();
         if ( ret )
             break;
 
index ffc84a53a88814f87a1308bcde9d1fff555eb786..8d67bbd11478e1fa212d7e02294c472419c77eb6 100644 (file)
@@ -132,7 +132,7 @@ struct xsm_operations {
     int (*physinfo) (void);
     int (*platform_quirk) (uint32_t);
     int (*firmware_info) (void);
-    int (*efi_runtime_call) (void);
+    int (*efi_call) (void);
     int (*acpi_sleep) (void);
     int (*change_freq) (void);
     int (*getidletime) (void);
@@ -554,9 +554,9 @@ static inline int xsm_firmware_info (void)
     return xsm_call(firmware_info());
 }
 
-static inline int xsm_efi_runtime_call (void)
+static inline int xsm_efi_call (void)
 {
-    return xsm_call(efi_runtime_call());
+    return xsm_call(efi_call());
 }
 
 static inline int xsm_acpi_sleep (void)